<#include 'global.ftl'>

<#macro header title>
<!DOCTYPE html>
<html lang="zh">
<head>
  <meta charset="utf-8">
  <meta name="viewport" content="width=device-width, initial-scale=1">
  <#-- <link rel="shortcut icon" href="../../assets/ico/favicon.ico"> -->
  <title>${title!''}</title>
  <script>
    window.GLOBAL = {
      CTX: '${ctx}'
    };
  </script>
  <link href="${cssRoot}/app.css" rel="stylesheet">
  <#nested>
</head>
</#macro>

<#macro body menu="菜单名称" cls='page-index'>
  <body class="${cls}">
    <div class="wrapper">
      <#include 'header.ftl'>
      <#include 'sidebar.ftl'>
      <section>
        <div class="content-wrapper">
          <#nested>
        </div>
      </section>
    </div>
</#macro>

<#macro breadcrumb crumbs>
<div class="crumb">
  <ol class="breadcrumb">
  <#list crumbs as crumb>
    <li<#if !(crumb_has_next)> class="active"</#if>>
      <#if crumb[1] != ''>
        <a href="${crumb[1]}">${crumb[0]}</a>
      <#else>
        ${crumb[0]}
      </#if>
    </li>
  </#list>
  </ol>
</div>
</#macro>



<#macro footer>
  <#include 'script.ftl'>
  <script>
  seajs.use(['${appRoot}/common/layout.js']);
  </script>
  <script src="${jsRoot}/bugsnag-2.min.js"
    data-apikey="50a141baa15882cbfe680c0d7545ebbe">
  </script>
  <#nested>
</body>
</html>
</#macro>
